import pymongo
import json

conn = pymongo.Connection('localhost',27017)
db = conn.storage

print db.rule_model.find().count()

for rm in db.rule_model.find():
    print rm['_id']
    #print json.dumps(rm)



		
